import re

class Settings:
    def __init__(self,difficulty=6):
        self.difficulty = difficulty
        self.color_list = ["lime","green",]
        self.wrong_color = ["orange","red"]


def add_word():
    with open("new_word.txt","r") as nw:
        with open("newn.txt","a") as nn:
            dump = nw.read()
            word_list = re.findall(r"[^a-zA-Z]?[a-zA-Z]{5,6}[^a-zA-Z]?"
                                   ,dump)
            for i in word_list:
                nn.write(i.strip(",.?!;:\'\"()-_+=@#/\n\t").strip().lower()+'\n')

if __name__ == '__main__':
    add_word()




















